﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    enum Fist
    {
        石头 = 1,
        剪刀,
        布,
    }
    class Machine : Father
    {

        public Machine(string name) : base(name)
        {
            this.Name = name;
        }
        public int punch()
        {
            Random random = new Random();
            int num = random.Next(1, 4);
            Fist f = (Fist)num;
            Console.WriteLine("{0},出拳：{1}", base.Name, f);
            return num;
        }

    }
}
